home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
bbsutil
/
125adev.zip
/
MESSREAD.BAS
< prev
next >
Wrap
BASIC Source File
|
1993-08-08
|
2KB
|
88 lines
defint a-z
type messagetype
fromlen as string * 1
from as string * 40
tolen as string * 1
toname as string * 40
private as string * 1
datelen as string * 1
date as string * 8
timelen as string * 1
time as string * 8
thread as integer
startline as long
endline as long
aboutlen as string * 1
about as string * 50
deleted as string * 1
received as string * 1
timesread as integer
netmailsent as string * 1
netmailkill as string * 1
killafterrcv as string * 1
recvreceipt as string * 1
fileattach as string * 1
attachfiledirnumb as integer
attachname as string * 13
sendnetmail as string * 1
msnumber as long
prevmess as long
nothing as string * 61
end type
type texttype
linelen as string * 1
linetxt as string * 127
end type
declare function pdqexist%(st$)
declare function pdqvali%(st$)
declare function midchar%(st$,ps%)
dim ms as messagetype
dim tx as texttype
zlf$=chr$(10)
messf$="messages\1.MES"
txf$="MESSAGES\1.TX"
if not pdqexist(messf$) then end 1
print "Which Record # in message file?"
line input a$
av=pdqvali%(a$)
open messf$ for random shared as 1 len=256
open txf$ for random shared as 2 len=128
get #1, av, ms
close 1
print " MESSAGE NUMBER"ms.msnumber
print "Message From: "left$(ms.from,asc(ms.fromlen))
print "Message To: "left$(ms.toname,asc(ms.tolen))
print "Message Subject: "left$(ms.about,asc(ms.aboutlen))
print
for t&=ms.startline to ms.endline
get #2, t&, tx
stl=asc(tx.linelen)
st$=left$(tx.linetxt,stl)
lfs=0
clf:
if midchar(st$,stl)=1 then lfs=lfs+1:stl=stl-1:st$=left$(st$,stl):goto clf
print st$
for a=1 to lfs
print zlf$;
next
next
close 2
end 0